package com.aaa.dao;

import com.aaa.entity.Permission;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface PermissionDao extends BaseMapper<Permission> {
    @Select("select p.* from user_role ur join role_permission rp on ur.roleid=rp.roleid join permission p on p.perid=rp.perid where ur.userid=#{userid}")
    List<Permission> selectByUserId(Object userid);
}
